import 'package:provider/provider.dart';
import 'package:flutter/material.dart';
import 'package:localstorage/localstorage.dart';
import 'package:shared_preferences/shared_preferences.dart';

class User with ChangeNotifier {
  String user;
  String token;

  setUser(user,token) async{
    SharedPreferences prefs = await SharedPreferences.getInstance();
    prefs.setString('token',token);
  }

  getUser() async{
    SharedPreferences prefs = await SharedPreferences.getInstance();
    return prefs.getString('token');
  }

}
